﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.VisualStudio.Modeling;
using System.ComponentModel;
using Microsoft.VisualStudio.Modeling.Diagrams;

namespace DSLFactory.VSCTDesigner
{
    partial class CommandWithIconBaseTypeDescriptor 
    {

        public PropertyDescriptorCollection GetCustomProperties(Attribute[] attributes)
        {
            // Get the default property descriptors from the base class
            global::System.ComponentModel.PropertyDescriptorCollection propertyDescriptors = base.GetProperties(attributes);

            //// Get a reference to the model element that is being described.
            //Button source = this.ModelElement as Button;
            //if( source != null )
            //{
            //    foreach( DomainRoleInfo sourceRole in source.GetDomainClass().AllDomainRolesPlayed )
            //    {
            //        if( sourceRole.DomainRelationship.Id == ButtonHasIcon.DomainClassId )
            //        {
            //            Attribute[] attrs = null;
            //            propertyDescriptors.Add(this.CreateRolePlayerPropertyDescriptor(source, sourceRole.OppositeDomainRole, attrs));
            //            break;
            //        }
            //    }
            //}

            // Return the property descriptors for this element
            return propertyDescriptors;
        }

    }
}
